package qingke.hibernate.bean;

import java.util.Set;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.OneToMany;
import javax.persistence.Table;

@Entity
@Table(name = "score")
public class Score {
	@Id
	@Column(name = "id")
	private int id;
	@Column(name = "create_time")
	private int createTime;
	@Column(name = "score")
	private int score;
	
	@OneToMany
	@JoinColumn(name = "score_id")
	private Set<CourseSelect> courseSelect;

	public int getId() {
		return id;
	}

	public void setId(int id) {
		this.id = id;
	}

	public int getCreateTime() {
		return createTime;
	}

	public void setCreateTime(int createTime) {
		this.createTime = createTime;
	}

	public int getScore() {
		return score;
	}

	public void setScore(int score) {
		this.score = score;
	}

	public Set<CourseSelect> getCourseSelect() {
		return courseSelect;
	}

	public void setCourseSelect(Set<CourseSelect> courseSelect) {
		this.courseSelect = courseSelect;
	}

	@Override
	public String toString() {
		return "Score [id=" + id + ", createTime=" + createTime + ", score=" + score + "]";
	}

	
}
